<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ page import="java.sql.*" %>
<%@ page contentType="text/html; charset=utf-8"%>
<jsp:useBean id="insert" class="bean.notebean"></jsp:useBean>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>留言插入</title>
</head>
<body>

<%
	String name   =(String)session.getAttribute("username");
	String subject=request.getParameter("subject");
	String note   =request.getParameter("note");
try{
	if(insert.insertnote(name ,subject, note)){
		out.println("留言发表成功！");
        out.println("<a href='note.jsp'>继续留言</a>"); 
    }else{
    	out.println("留言发表失败！");
    }     
	   }catch(Exception ex){
	     ex.printStackTrace();
	    }
	    %>



</body>
</html>